﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace assignment5
{
    internal class OrderDetails
    {

        private int itemNum;
        private string itemName;
        private int price;//商品单价
        
        public int ItemNum { get { return itemNum; } set { itemNum = value; } }
        public string ItemName { get { return itemName; } set { itemName = value; } }

        public int Price { get { return price; } set { price = value; } }

        public OrderDetails(int itemNum,string itemName, int price)
        {
            ItemNum = itemNum;
            ItemName = itemName;
            Price = price;
        }

        public OrderDetails() { }
        

        public  void ToString(OrderDetails orderDetails)
        {
             Console.WriteLine(orderDetails.ItemNum+", "+ orderDetails.ItemName+ ", " 
                 + orderDetails.Price);
        }
    }
}
